package com.gnerv.business.platform.entity;

import com.baomidou.mybatisplus.activerecord.Model;
import com.baomidou.mybatisplus.annotations.TableField;
import com.baomidou.mybatisplus.annotations.TableName;

import java.io.Serializable;

/**
 * @description: 平台角色
 * @author: Gnerv LiGen
 * @date: 2018-07-03
 **/
@TableName(value = "platform_role")
public class Role extends Model<Role> implements Serializable {

    private static final long serialVersionUID = 1L;

    private Long id;
    @TableField(value = "role_id")
    private String roleId;
    @TableField(value = "p_id")
    private String pId;
    @TableField(value = "role_name")
    private String roleName;

    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        this.id = id;
    }

    public String getRoleId() {
        return roleId;
    }

    public void setRoleId(String roleId) {
        this.roleId = roleId;
    }

    public String getpId() {
        return pId;
    }

    public void setpId(String pId) {
        this.pId = pId;
    }

    public String getRoleName() {
        return roleName;
    }

    public void setRoleName(String roleName) {
        this.roleName = roleName;
    }

    @Override
    public String toString() {
        return "Role{" +
                "id=" + id +
                ", roleId='" + roleId + '\'' +
                ", pId='" + pId + '\'' +
                ", roleName='" + roleName + '\'' +
                '}';
    }

    @Override
    protected Serializable pkVal() {
        return this.id;
    }
}
